<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>Wrapper for assorted list commands</title>

 </head>
 <body><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="mysqlnduhconnection.listfields.html">MysqlndUhConnection::listFields</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="mysqlnduhconnection.moreresults.html">MysqlndUhConnection::moreResults</a></div>
 <div class="up"><a href="class.mysqlnduhconnection.html">MysqlndUhConnection</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div><hr /><div id="mysqlnduhconnection.listmethod" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">MysqlndUhConnection::listMethod</h1>
  <p class="verinfo">(PECL mysqlnd-uh &gt;= 1.0.0-alpha)</p><p class="refpurpose"><span class="refname">MysqlndUhConnection::listMethod</span> &mdash; <span class="dc-title">Wrapper for assorted list commands</span></p>

 </div>

 <div class="refsect1 description" id="refsect1-mysqlnduhconnection.listmethod-description">
  <h3 class="title">说明</h3>
  <div class="methodsynopsis dc-description">
   <span class="modifier">public</span> <span class="type"><span class="type void">void</span></span> <span class="methodname"><strong>MysqlndUhConnection::listMethod</strong></span>
    ( <span class="methodparam"><span class="type"><span class="type mysqlnd_connection">mysqlnd_connection</span></span> <code class="parameter">$connection</code></span>
   , <span class="methodparam"><span class="type">string</span> <code class="parameter">$query</code></span>
   , <span class="methodparam"><span class="type">string</span> <code class="parameter">$achtung_wild</code></span>
   , <span class="methodparam"><span class="type">string</span> <code class="parameter">$par1</code></span>
   )</div>

  <p class="para rdfs-comment">
   Wrapper for assorted list commands.
  </p>

  <div class="warning"><strong class="warning">Warning</strong><p class="simpara">本函数还未编写文档，仅有参数列表。</p></div>

 </div>


 <div class="refsect1 parameters" id="refsect1-mysqlnduhconnection.listmethod-parameters">
  <h3 class="title">参数</h3>
  <dl>

   
    <dt>
<em><code class="parameter">connection</code></em></dt>

    <dd>

     <p class="para">
      Mysqlnd connection handle. Do not modify!
     </p>
    </dd>

   
   
    <dt>
<em><code class="parameter">query</code></em></dt>

    <dd>

     <p class="para">
      SHOW command to be executed.
     </p>
    </dd>

   
   
    <dt>
<em><code class="parameter">achtung_wild</code></em></dt>

    <dd>

     <p class="para">

     </p>
    </dd>

   
   
    <dt>
<em><code class="parameter">par1</code></em></dt>

    <dd>

     <p class="para">

     </p>
    </dd>

   
  </dl>

 </div>


 <div class="refsect1 returnvalues" id="refsect1-mysqlnduhconnection.listmethod-returnvalues">
  <h3 class="title">返回值</h3>
  <p class="para">

  </p>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-mysqlnduhconnection.listmethod-returnvalues">
  <h3 class="title">返回值</h3>
  <p class="para">
   TODO
  </p>
 </div>


 <div class="refsect1 examples" id="refsect1-mysqlnduhconnection.listmethod-examples">
  <h3 class="title">范例</h3>
  <p class="para">
   <div class="example" id="example-1873">
    <p><strong>Example #1 <span class="function"><strong>MysqlndUhConnection::listMethod()</strong></span> example</strong></p>
        <div class="example-contents">
<div class="phpcode"><code><span style="color: #000000">
<span style="color: #0000BB">&lt;?php<br /></span><span style="color: #007700">class&nbsp;</span><span style="color: #0000BB">proxy&nbsp;</span><span style="color: #007700">extends&nbsp;</span><span style="color: #0000BB">MysqlndUhConnection&nbsp;</span><span style="color: #007700">{<br />&nbsp;public&nbsp;function&nbsp;</span><span style="color: #0000BB">listMethod</span><span style="color: #007700">(</span><span style="color: #0000BB">$res</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">$query</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">$pattern</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">$par1</span><span style="color: #007700">)&nbsp;{<br />&nbsp;&nbsp;</span><span style="color: #0000BB">printf</span><span style="color: #007700">(</span><span style="color: #DD0000">"%s(%s)\n"</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">__METHOD__</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">var_export</span><span style="color: #007700">(</span><span style="color: #0000BB">func_get_args</span><span style="color: #007700">(),&nbsp;</span><span style="color: #0000BB">true</span><span style="color: #007700">));<br />&nbsp;&nbsp;</span><span style="color: #0000BB">$ret&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">parent</span><span style="color: #007700">::</span><span style="color: #0000BB">listMethod</span><span style="color: #007700">(</span><span style="color: #0000BB">$res</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">$query</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">$pattern</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">$par1</span><span style="color: #007700">);<br />&nbsp;&nbsp;</span><span style="color: #0000BB">printf</span><span style="color: #007700">(</span><span style="color: #DD0000">"%s&nbsp;returns&nbsp;%s\n"</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">__METHOD__</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">var_export</span><span style="color: #007700">(</span><span style="color: #0000BB">$ret</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">true</span><span style="color: #007700">));<br />&nbsp;&nbsp;return&nbsp;</span><span style="color: #0000BB">$ret</span><span style="color: #007700">;<br />&nbsp;}<br />}<br /></span><span style="color: #0000BB">mysqlnd_uh_set_connection_proxy</span><span style="color: #007700">(new&nbsp;</span><span style="color: #0000BB">proxy</span><span style="color: #007700">());<br /><br /></span><span style="color: #0000BB">$mysql&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">mysql_connect</span><span style="color: #007700">(</span><span style="color: #DD0000">"localhost"</span><span style="color: #007700">,&nbsp;</span><span style="color: #DD0000">"root"</span><span style="color: #007700">,&nbsp;</span><span style="color: #DD0000">""</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">$res&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">mysql_list_dbs</span><span style="color: #007700">(</span><span style="color: #0000BB">$mysql</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">printf</span><span style="color: #007700">(</span><span style="color: #DD0000">"num_rows&nbsp;=&nbsp;%d\n"</span><span style="color: #007700">,&nbsp;</span><span style="color: #0000BB">mysql_num_rows</span><span style="color: #007700">(</span><span style="color: #0000BB">$res</span><span style="color: #007700">));<br />while&nbsp;(</span><span style="color: #0000BB">$row&nbsp;</span><span style="color: #007700">=&nbsp;</span><span style="color: #0000BB">mysql_fetch_assoc</span><span style="color: #007700">(</span><span style="color: #0000BB">$res</span><span style="color: #007700">))<br />&nbsp;</span><span style="color: #0000BB">var_dump</span><span style="color: #007700">(</span><span style="color: #0000BB">$row</span><span style="color: #007700">);<br /></span><span style="color: #0000BB">?&gt;</span>
</span>
</code></div>
    </div>

    <div class="example-contents"><p>以上例程会输出：</p></div>
    <div class="example-contents screen">
<div class="cdata"><pre>
proxy::listMethod(array (
  0 =&gt; NULL,
  1 =&gt; &#039;SHOW DATABASES&#039;,
  2 =&gt; &#039;&#039;,
  3 =&gt; &#039;&#039;,
))
proxy::listMethod returns NULL
num_rows = 6
array(1) {
  [&quot;Database&quot;]=&gt;
  string(18) &quot;information_schema&quot;
}
array(1) {
  [&quot;Database&quot;]=&gt;
  string(5) &quot;mysql&quot;
}
array(1) {
  [&quot;Database&quot;]=&gt;
  string(8) &quot;oxid_new&quot;
}
array(1) {
  [&quot;Database&quot;]=&gt;
  string(7) &quot;phptest&quot;
}
array(1) {
  [&quot;Database&quot;]=&gt;
  string(7) &quot;pushphp&quot;
}
array(1) {
  [&quot;Database&quot;]=&gt;
  string(4) &quot;test&quot;
}
</pre></div>
    </div>
   </div>
  </p>
 </div>


 <div class="refsect1 seealso" id="refsect1-mysqlnduhconnection.listmethod-seealso">
  <h3 class="title">参见</h3>
  <p class="para">
   <ul class="simplelist">
    <li class="member">
     <span class="function"><a href="function.mysqlnd-uh-set-connection-proxy.html" class="function" rel="rdfs-seeAlso">mysqlnd_uh_set_connection_proxy()</a> - Installs a proxy for mysqlnd connections</span>
    </li>
    <li class="member">
     <span class="function"><a href="function.mysql-list-dbs.html" class="function" rel="rdfs-seeAlso">mysql_list_dbs()</a> - 列出 MySQL 服务器中所有的数据库</span>
    </li>
   </ul>
  </p>
 </div>


</div><hr /><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="mysqlnduhconnection.listfields.html">MysqlndUhConnection::listFields</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="mysqlnduhconnection.moreresults.html">MysqlndUhConnection::moreResults</a></div>
 <div class="up"><a href="class.mysqlnduhconnection.html">MysqlndUhConnection</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div></body></html>
